-
Notifications
You must be signed in to change notification settings - Fork 0
[CLEAN] Synthetic Benchmark PR #138557 - Flat index resolution #25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: base_pr_138557_20251204_4885
Are you sure you want to change the base?
[CLEAN] Synthetic Benchmark PR #138557 - Flat index resolution #25
Conversation
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||||||||
PR Code Suggestions ✨No code suggestions found for the PR. |
User description
Benchmark PR elastic#138557
Type: Clean (correct implementation)
Original PR Title: Flat index resolution
Original PR Description: Flat index resolution for an esql query. This includes:
Original PR URL: Flat index resolution elastic/elasticsearch#138557
PR Type
Enhancement
Description
Add flat index resolution for ESQL queries in CPS environments
Implement cross-project mode support with flat world indices resolution
Refactor index resolution to support both standard and flat world modes
Simplify cluster initialization with new
initClustermethodDiagram Walkthrough
flowchart LR A["ESQL Query"] --> B{Cross Project<br/>Mode Enabled?} B -->|No| C["Standard Index<br/>Resolution"] B -->|Yes| D["Flat World Index<br/>Resolution"] C --> E["Initialize Clusters<br/>from Grouper"] D --> F["Initialize Clusters<br/>from FC Response"] E --> G["EsqlExecutionInfo"] F --> GFile Walkthrough
EsqlExecutionInfo.java
Add initCluster method for cluster initializationx-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/EsqlExecutionInfo.java
initClustermethod to initialize cluster entries with indexexpression and skip unavailable settings
index expressions when cluster already exists
EsqlCCSUtils.java
Add EsIndex-based cluster initializationx-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/session/EsqlCCSUtils.java
initCrossClusterStatethat acceptsEsIndexandinitializes clusters from resolved indices
initCrossClusterStateto use newinitClustermethodinstead of inline cluster creation
EsIndexclassEsqlSession.java
Implement flat world index resolution pathx-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/session/EsqlSession.java
preAnalyzeMainIndicesto route toeither standard or flat world resolution
preAnalyzeFlatMainIndicesmethod for flat world indexresolution
createQueryFiltermethod
preAnalyzeLookupIndexby removing redundant parameterspreAnalyzeMainIndicesIndexResolver.java
Refactor index resolution with flat world supportx-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/session/IndexResolver.java
FIELD_CAPS_INDICES_OPTIONStoDEFAULT_OPTIONSfor clarityFLAT_WORLD_OPTIONSconfiguration for flat world/CPS contextresolution
resolveIndicesandresolveIndicesVersionedmethods withsimplified signatures
resolveFlatWorldIndicesVersionedmethod for flat world indexresolution
doResolveIndicesmethodFunctionparameter with newOriginalIndexExtractorinterfacefor better type safety
createFieldCapsRequestto acceptIndicesOptionsparameter andsupport
includeResolvedToflagDO_NOT_GROUPconstant for standard index extractionEnrichPolicyResolver.java
Simplify index resolution call parametersx-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/enrich/EnrichPolicyResolver.java
resolveIndicescall by removing redundant parameters (null,false, false, false)
QueryBuilderResolver.java
Update indices options referencex-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/expression/function/fulltext/QueryBuilderResolver.java
IndexResolver.FIELD_CAPS_INDICES_OPTIONStoIndexResolver.DEFAULT_OPTIONSfor consistencyAnalyzerTests.java
Update tests to use DO_NOT_GROUP constantx-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/analysis/AnalyzerTests.java
IndexResolver.mergedMappingsto useIndexResolver.DO_NOT_GROUPinstead of lambda expressionsEsqlDataTypeRegistryTests.java
Update test to use DO_NOT_GROUP constantx-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/type/EsqlDataTypeRegistryTests.java
IndexResolver.mergedMappingsto useIndexResolver.DO_NOT_GROUPinstead of lambda